import React, { Component } from 'react'
import '../../static/routineMonitoring/keyPerson.less'

class keyPerson extends Component {
  constructor(props) {
    super(props)
    this.state ={
      navChangeColor: 0
    }
  }

  onNav(num) {  
    this.setState({
      navChangeColor: num
    })
  }

  render() {
    return (
      <div className='keyPerson'>
        <div className='keyPerson_nav'>
          <div onClick={this.onNav.bind(this,0)}
            className={this.state.navChangeColor === 0?'keyPerson_nav_title keyPersonActive':'keyPerson_nav_title'}>重点人</div>
          <div onClick={this.onNav.bind(this,1)}
            className={this.state.navChangeColor === 1?'keyPerson_nav_title keyPersonActive':'keyPerson_nav_title'}>重点组织</div>
        </div>
        <div className='keyPerson_bottom'>
          <div className='keyPerson_left'>1</div>
          <div className='keyPerson_middle'>2</div>
          <div className='keyPerson_right'>3</div>
        </div>
      </div>
    )
  }
}

export default keyPerson